DevNet Resource Kit Article

Blog Man

Blog Man is a blog manager built in ColdFusion. This application balances manageability with scalability, and features many of the tools you've probably seen in Movable Type and other blog applications.

Blog Man supports RDMS systems, including Microsoft SQL Server 2000, Microsoft Access, and mySQL. This version of Blog Man has been completely rewritten from the ground up to support enterprise blogging applications easily. Whether on the road or in the office, people always have access to Blog Man. Users can now post to their blog from any mobile device that has the capability of sending e-mail.

Other blog applications require you to republish the entire site whenever you make a change. This is too much work. Because Blog Man uses includes to include the header and footer of the template, this eliminates the need to republish your site when you make changes.

Installing Blog Man

  1. Add a datasource with the name blogman_v2. Point this datasource to either the default Access database included with the installation (assets/data/blogman.mdb), upsize the Access database to SQL 2000, or create a mySQL database from the included mySQL database files (assets/data/blogman_v2).
  2. Create two mappings in the ColdFusion Administrator, one called blogman_v2 pointing to the component directory (com/blogman_v2/), the other called blogman_v2_site pointing to the root of the blog.
  3. Open the root Application.cfm file and change lines 23, 24, 28, 29, 31, 40, and 41 to values that are appropriate for you.
  4. Lines 40 and 41 are for Moblogging (mobile blogging). Create a mail account on your mail server with the e-mail address and password that you set for these lines. If you want to post to your blog with an e-mail client, simply send your message to this address. Whatever image file you attach to that e-mail is included automatically in the post. The subject is the title of your post and the body is the text of the post.
  5. Log in to the admin located at /blogman_v2/admin/ with admin as the username and password.
  6. Browse to the Manage Users section and add a user. This will be your login for the future. Now log out and log back in with the user you just created.
  7. Go back to the Manage Users section and remove the default user by clicking the delete icon.
  8. Go to the Manage Templates section and click Save Changes to build your blog.

Now you can add entries, categories, and so on. That's all there is to it!

Upgrading Blog Man

  1. Follow the steps above.
  2. Click the Import Entries section and enter the webroot path of your old XML folder. For example, e:\wwwroot\www.cfm-applications.com\blogman\xml\. This imports your previous data except comment subscriptions, e-mail subscriptions, and related entries.

That's all there is to it!

Frequently Asked Questions

How do I manage my site template?

Your site template is stored in the assets folder root. You have two options for creating your site design:

  • Create your template file and put it in the assets root folder with the name _template.html.
  • Enter the HTML in the Manage Templates Textarea section in the admin.

You have to log in and go to the Manage Templates section and click Save Changes. After you save changes, it creates a header and footer file, creates your index page, and parses the index page looking for Blog Man variables (see next question).

How do I use Blog Man variables?

Blog Man has the following variables available:

<$blogman:blogtitle/$> When Blog Man parses this variable it fills its value with the value you gave request.blogtitle in the root Application.cfm page.

<$blogman:globalcss/$> When Blog Man parses this variable it fills its value with the HTML code for the link to the CSS file for your design. This is the assets/css/global.css file.

<$blogman:globaljsscript/$> When Blog Man parses this variable it fills its value with the HTML code for the link to the JavaScript file for the comments and e-mail subscription validations, along with the open comments link and the print entry window scripts. This is the assets/js/global.js file.

<$blogman:absoluteurl/$> When Blog Man parses this variable it fill its value with the value you gave the request.absoluteurl value in the root Application.cfm file. This value is used for any path locations for images, JavaScript files, CSS files, Macromedia Flash files, and others that you would like to use in your design.
For example, <img src="<$blogman:absoluteurl/$>assets/images/yourlogo.gif">.

<$blogman:calendar/$> When Blog Man parses this variable it fills its value with the cfinclude file to the HTML display of the calendar. The included file is located in the assets/includes folder called _calendar.cfm.

<$blogman:resourcefeeds/$> When Blog Man parses this variable it fills its value with the cfinclude file to the HTML display of the link to the RSS feed. The included file is located in the assets/includes folder called _resourcefeeds.cfm.

<$blogman:archives/$> When Blog Man parses this variable it fills its value with the cfinclude file to the HTML display of the link to the archives. The included file is located in the assets/includes folder called _archives.cfm.

<$blogman:recententries/$> When Blog Man parses this variable it fills its value with the cfinclude file to the HTML display of the link to the recent entries. The included file is located in the assets/includes folder called _recententries.cfm.

<$blogman:emailsubscriptions/$> When Blog Man parses this variable it fills its value with the cfinclude file to the HTML display of the link to the e-mail subscriptions form. The included file is located in the assets/includes folder called _emailsubscriptions.cfm.

You can modify the design for the files in the assets/includes folder.

Planned Features (The Short List!)

Among the planned featured for Blog Man are the following:

  • VoiceXML, which allows you to publish to your Blog Man application by recording a message on your mobile device.
  • Track Back listing, which allows other users of Blog Man to link easily to an entry of yours—and you to link easily to an entry of theirs.
  • The ability to track and record visitor information, such as the number of hits, most popular entry, number of views, and so on.
  • Industry-leading spam filtering techniques, such as regular expression black lists, IP banning, easy removal of spam comments, and so on.
  • "Just listen" functionality so a potential comment poster can follow the comments that have been posted to an entry without commenting themselves.
  • Enhanced entry comments
  • And many more.

Feel free to e-mail the author with any comments or suggestions at bryan.hogan@cfm-applications.com.